package com.group01.mapper;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.github.yulichang.base.MPJBaseMapper;
import com.group01.dto.Order.OrderItemDTO;
import com.group01.pojo.OrderItem;
import com.group01.vo.OrderItem.OrderItemVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;


/**
* @author 19559
* @description 针对表【es_order_item(订单项表)】的数据库操作Mapper
* @createDate 2024-06-22 12:40:23
* @Entity com.group01.pojo.OrderItem
*/
public interface OrderItemMapper extends MPJBaseMapper<OrderItem> {

    /**
     * 根据订单id查询订单项以及具体的商品信息
     */
    List<OrderItemVO> selectOrderItemAndProductByOrderId(@Param(Constants.WRAPPER) Wrapper<OrderItem> wrapper);

    /**
     * 批量新增OrderItem
     */
    Integer batchInsertOrderItem(@Param("uuid") String uuid, @Param("orderItemList") List<OrderItemDTO> orderItemList);
}




